Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@sigstore/tuf

Package Overview
Dependencies
Maintainers
2
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@sigstore/tuf

Client for the Sigstore TUF repository

  • 1.0.3
  • Source
  • npm
  • Socket score

Version published
Maintainers
2
Created

What is @sigstore/tuf?

@sigstore/tuf is an npm package that provides functionalities for secure software supply chain management using The Update Framework (TUF). It helps in ensuring the integrity and authenticity of software updates.

What are @sigstore/tuf's main functionalities?

Initialize TUF Client

This feature allows you to initialize a TUF client with a specified remote repository URL and a local cache path. The TUF client is used to interact with the TUF repository for secure updates.

const { TUFClient } = require('@sigstore/tuf');
const client = new TUFClient({
  remoteRepoURL: 'https://example.com/tuf-repo',
  localCachePath: './tuf-cache'
});

Fetch Metadata

This feature allows you to fetch metadata from the TUF repository. In this example, it fetches the 'root.json' metadata file and logs it to the console.

async function fetchMetadata() {
  const metadata = await client.getMetadata('root.json');
  console.log(metadata);
}
fetchMetadata();

Verify Targets

This feature allows you to verify the integrity and authenticity of a target file using the TUF client. It checks if the target file is valid according to the TUF metadata.

async function verifyTarget(targetFile) {
  const isValid = await client.verifyTarget(targetFile);
  console.log(`Target ${targetFile} is valid: ${isValid}`);
}
verifyTarget('example-target.txt');

Other packages similar to @sigstore/tuf

FAQs

Package last updated on 19 Jul 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc